package com.arithmetic.version2;

public class AdditionOperation extends BinaryOperation {

    public AdditionOperation() {
        super();
        this.operator = '+';
    }

    public AdditionOperation(int left, int right) {
        super(left, right, '+');
    }

    @Override
    public int calculate() {
        return leftOperand + rightOperand;
    }

    @Override
    public boolean checkingCalculation(int result) {
        return result == (leftOperand + rightOperand);
    }
}
